[Slack Alert] Facebook Ads URL Check
Use this automation to make sure that all landing pages are responsive and accessible for all of your active Facebook ads. You will get a Slack notification for any ads that have non-functioning URLs.
With this automation, get a Slack message for any ads with non-functioning URLs.
JSON Recipe
Import the automation recipe(s) into your account. Don’t know how? Learn here.
{"name":"Facebook Ads URL Check","description":"","nodes":{"delay_1":{"type":"delay","logging_enabled":false,"error_rules":[],"x":72,"y":617,"inputs":{"duration":{"export_enabled":true,"data":21600}}},"fb_select_ad_account_ids_v2_1":{"type":"fb_select_ad_account_ids_v2","logging_enabled":false,"error_rules":[],"x":30,"y":174,"group":"group_1","inputs":{"ad_account_ids":{"title":"ad_account_ids","description":"Select one or more Facebook Accounts"}}},"stop_1":{"type":"stop","logging_enabled":false,"error_rules":[],"x":23,"y":538,"inputs":{"stop":{"export_enabled":true}}},"start_1":{"type":"start","logging_enabled":false,"error_rules":[],"x":20,"y":321},"if_v2_1":{"type":"if_v2","logging_enabled":false,"error_rules":[],"x":963,"y":301,"inputs":{"b":{"export_enabled":true,"data":[]},"condition":{"export_enabled":true,"data":"not_equal"}}},"slack_select_conversation_id_1":{"type":"slack_select_conversation_id","logging_enabled":false,"error_rules":[],"x":14,"y":162,"group":"group_2","inputs":{"conversation_id":{"title":"conversation_id","description":"Select a Slack Channel or Conversation"}}},"slack_notifier_v2_1":{"type":"slack_notifier_v2","logging_enabled":false,"error_rules":[],"x":357,"y":337,"group":"group_2","inputs":{"blocks":{"export_enabled":true,"data":[{"type":"section","text":{"type":"mrkdwn","text":"⚠️These ad(s) have a non-functioning URL."}}]},"thread_ts":{"export_enabled":true}}},"slack_notifier_v2_2":{"type":"slack_notifier_v2","logging_enabled":false,"error_rules":[],"x":1790,"y":289,"group":"group_2"},"for_each_v2_1":{"type":"for_each_v2","logging_enabled":false,"error_rules":[],"x":699,"y":243,"group":"group_2"},"health_check_urls_v2_1":{"type":"health_check_urls_v2","title":"Health Check Urls","description":"Checks urls for their health","logging_enabled":false,"max_job_retries":6,"timeout":90,"error_rules":[],"x":856,"y":319,"group":"group_3","inputs":{"follow_redirects":{"export_enabled":true,"data":true},"max_request_duration":{"export_enabled":true,"data":10000}}},"replace_list_string_1":{"type":"replace_list_string","logging_enabled":false,"error_rules":[],"x":38,"y":355,"group":"group_3","inputs":{"value":{"export_enabled":true,"data":""},"regex":{"export_enabled":true,"data":"\\?.*"},"pointer":{"export_enabled":true,"data":"/url"},"schema":{"export_enabled":true,"data":"url_with_id"}}},"split_list_1":{"type":"split_list","logging_enabled":false,"error_rules":[],"x":348,"y":351,"group":"group_3","inputs":{"size":{"export_enabled":true,"data":10}}},"filter_v2_1":{"type":"filter_v2","logging_enabled":false,"error_rules":[],"x":1356,"y":461,"group":"group_3","inputs":{"filters":{"export_enabled":true,"data":[{"value":400,"pointer":"/code","operator":"\u003e="}]}}},"append_1":{"type":"append","logging_enabled":false,"error_rules":[],"x":1117,"y":349,"group":"group_3","inputs":{"flatten":{"export_enabled":true,"data":true},"schema":{"export_enabled":true,"data":"any"}}},"for_each_v2_2":{"type":"for_each_v2","logging_enabled":false,"error_rules":[],"x":596,"y":329,"group":"group_3"},"fb_extract_ad_urls_v2_1":{"type":"fb_extract_ad_urls_v2","logging_enabled":false,"error_rules":[],"x":1107,"y":380,"group":"group_1"},"fb_fetch_adset_ad_ids_v2_1":{"type":"fb_fetch_adset_ad_ids_v2","logging_enabled":false,"error_rules":[],"x":813,"y":326,"group":"group_1","inputs":{"effective_status":{"export_enabled":true,"data":["ACTIVE"]}}},"filter_v2_2":{"type":"filter_v2","logging_enabled":false,"error_rules":[],"x":1469,"y":429,"group":"group_1","inputs":{"filters":{"export_enabled":true,"data":[{"value":"https://itunes.apple.com","pointer":"/url","operator":"not_contains"},{"value":"https://play.google.com","pointer":"/url","operator":"not_contains"},{"operator":"not_contains","pointer":"/url","value":"fb.com"},{"operator":"not_contains","pointer":"/url","value":"fb.me"},{"operator":"not_contains","pointer":"/url","value":"instagram.com"}]}},"outputs":{"filtered":{"title":"filtered","description":"Triggered when filtered"}}},"fb_fetch_campaign_adset_ids_v2_1":{"type":"fb_fetch_campaign_adset_ids_v2","logging_enabled":false,"error_rules":[],"x":560,"y":270,"group":"group_1","inputs":{"effective_status":{"export_enabled":true,"data":["ACTIVE"]},"is_completed":{"export_enabled":true,"data":false}}},"fb_fetch_campaign_ids_v2_1":{"type":"fb_fetch_campaign_ids_v2","logging_enabled":false,"error_rules":[],"x":310,"y":226,"group":"group_1","inputs":{"effective_status":{"export_enabled":true,"data":["ACTIVE"]},"is_completed":{"export_enabled":true,"data":false}}},"patch_json_v2_1":{"type":"patch_json_v2","title":"Patch Json: Add ad data","description":"Apply JSON patches against data","logging_enabled":false,"max_job_retries":6,"timeout":30,"error_rules":[],"x":1244,"y":274,"group":"group_2","inputs":{"patches":{"export_enabled":true,"data":[{"op":"add","path":"/url/id/context/ad","value":"{{input.value}}"}]}}},"patch_json_v2_2":{"type":"patch_json_v2","title":"Patch Json: Build Message","description":"Apply JSON patches against data","logging_enabled":false,"max_job_retries":6,"timeout":30,"error_rules":[],"x":1533,"y":269,"group":"group_2","inputs":{"patches":{"export_enabled":true,"data":[{"op":"replace","path":"/0/text/text","value":"This URL has not been responsive: \n `{{input.value/url/url}}`."},{"op":"replace","path":"/1/elements/0/url","value":"https://business.facebook.com/adsmanager/manage/ads?act={{input.value/url/id/context/ad/account_id}}\u0026filter_set=SEARCH_BY_ADGROUP_IDS-STRING_SET%1EANY%1E[%22{{input.value/url/id/id}}%22]"}]},"data":{"export_enabled":true,"data":[{"type":"section","text":{"type":"mrkdwn","text":""}},{"type":"actions","elements":[{"type":"button","text":{"type":"plain_text","text":"Open in Ads Manager"},"url":""}]}]}}},"extract_v2_1":{"type":"extract_v2","logging_enabled":false,"error_rules":[],"x":958,"y":289,"group":"group_4","inputs":{"default_value":{"export_enabled":true},"pointer":{"export_enabled":true,"data":"/url/id/id"}}},"parse_string_to_id_1":{"type":"parse_string_to_id","logging_enabled":false,"error_rules":[],"x":1212,"y":305,"group":"group_4","inputs":{"schema":{"export_enabled":true,"data":"fb_ad_id"}}},"fb_fetch_ad_v2_1":{"type":"fb_fetch_ad_v2","logging_enabled":false,"error_rules":[],"x":1474,"y":306,"group":"group_4"}},"edges":[{"id":"if_v2_1.false:delay_1.start","points":[]},{"id":"filter_v2_2.items:replace_list_string_1.data_list","points":[]},{"id":"fb_extract_ad_urls_v2_1.urls:filter_v2_2.items","points":[]},{"id":"fb_extract_ad_urls_v2_1.extracted:filter_v2_2.filter","points":[]},{"id":"filter_v2_2.filtered:replace_list_string_1.replace","points":[]},{"id":"slack_notifier_v2_1.thread_ts:slack_notifier_v2_2.thread_ts","points":[]},{"id":"slack_select_conversation_id_1.conversation_id:slack_notifier_v2_2.conversation_id","points":[]},{"id":"slack_select_conversation_id_1.conversation_id:slack_notifier_v2_1.conversation_id","points":[]},{"id":"slack_notifier_v2_1.sent:for_each_v2_1.start","points":[]},{"id":"slack_notifier_v2_2.sent:for_each_v2_1.next","points":[]},{"id":"if_v2_1.true:slack_notifier_v2_1.send","points":[]},{"id":"filter_v2_1.items:for_each_v2_1.items","points":[]},{"id":"for_each_v2_1.done:delay_1.start","points":[]},{"id":"replace_list_string_1.replaced:append_1.reset","points":[]},{"id":"append_1.resetted:split_list_1.split","points":[]},{"id":"replace_list_string_1.data_list:split_list_1.data_list","points":[]},{"id":"split_list_1.list_of_lists:for_each_v2_2.items","points":[]},{"id":"split_list_1.split:for_each_v2_2.start","points":[]},{"id":"for_each_v2_2.do:health_check_urls_v2_1.check","points":[]},{"id":"health_check_urls_v2_1.results:append_1.item","points":[]},{"id":"append_1.list:filter_v2_1.items","points":[]},{"id":"append_1.appended:for_each_v2_2.next","points":[]},{"id":"filter_v2_1.filtered:if_v2_1.evaluate","points":[]},{"id":"for_each_v2_2.item:health_check_urls_v2_1.urls","points":[]},{"id":"health_check_urls_v2_1.checked:append_1.append","points":[]},{"id":"for_each_v2_2.done:filter_v2_1.filter","points":[]},{"id":"filter_v2_1.items:if_v2_1.a","points":[]},{"id":"fb_fetch_campaign_ids_v2_1.campaign_ids:fb_fetch_campaign_adset_ids_v2_1.campaign_ids","points":[]},{"id":"fb_fetch_campaign_adset_ids_v2_1.fetched:fb_fetch_adset_ad_ids_v2_1.fetch","points":[]},{"id":"fb_fetch_adset_ad_ids_v2_1.ad_ids:fb_extract_ad_urls_v2_1.ad_ids","points":[]},{"id":"fb_fetch_adset_ad_ids_v2_1.fetched:fb_extract_ad_urls_v2_1.extract","points":[]},{"id":"fb_fetch_campaign_ids_v2_1.fetched:fb_fetch_campaign_adset_ids_v2_1.fetch","points":[]},{"id":"fb_select_ad_account_ids_v2_1.ad_account_ids:fb_fetch_campaign_ids_v2_1.ad_account_ids","points":[]},{"id":"fb_fetch_campaign_adset_ids_v2_1.adset_ids:fb_fetch_adset_ad_ids_v2_1.adset_ids","points":[]},{"id":"delay_1.delayed:fb_fetch_campaign_ids_v2_1.fetch","points":[]},{"id":"start_1.start:fb_fetch_campaign_ids_v2_1.fetch","points":[]},{"id":"extract_v2_1.data:parse_string_to_id_1.value","points":[]},{"id":"extract_v2_1.extracted:parse_string_to_id_1.parse","points":[]},{"id":"parse_string_to_id_1.result:fb_fetch_ad_v2_1.ad_id","points":[]},{"id":"fb_fetch_ad_v2_1.fetched:patch_json_v2_1.patch","points":[]},{"id":"patch_json_v2_1.patched:patch_json_v2_2.patch","points":[]},{"id":"parse_string_to_id_1.parsed:fb_fetch_ad_v2_1.fetch","points":[]},{"id":"fb_fetch_ad_v2_1.ad:patch_json_v2_1.value","points":[]},{"id":"patch_json_v2_1.data:patch_json_v2_2.value","points":[]},{"id":"for_each_v2_1.do:extract_v2_1.extract","points":[]},{"id":"patch_json_v2_2.data:slack_notifier_v2_2.blocks","points":[]},{"id":"for_each_v2_1.item:extract_v2_1.data","points":[]},{"id":"for_each_v2_1.item:patch_json_v2_1.data","points":[]},{"id":"patch_json_v2_2.patched:slack_notifier_v2_2.send","points":[]}],"groups":{"group_2":{"title":"Send Slack Message","description":"","x":1324,"y":413,"inputs":["for_each_v2_1.items","slack_notifier_v2_1.send"],"outputs":["for_each_v2_1.done"]},"group_3":{"title":"Check URLs in batches","description":"","x":643,"y":291,"inputs":["replace_list_string_1.data_list","replace_list_string_1.replace"],"outputs":["filter_v2_1.items","filter_v2_1.filtered"]},"group_1":{"title":"Get URLs","description":"","x":322,"y":296,"inputs":["fb_fetch_campaign_ids_v2_1.fetch"],"outputs":["filter_v2_2.items","filter_v2_2.filtered"]},"group_4":{"title":"Fetch Ad","description":"","x":964,"y":286,"group":"group_2","inputs":["extract_v2_1.data","extract_v2_1.extract"],"outputs":["fb_fetch_ad_v2_1.fetched","fb_fetch_ad_v2_1.ad"]}},"widgets":{"widget_1":{"title":"Run every","description":"The duration to delay the trigger (in Seconds)","position":5,"icon":"las la-hourglass","input":"delay_1.duration"},"widget_2":{"title":"Facebook Ad Account","description":"Select Facebook Ad Account","position":0,"input":"fb_select_ad_account_ids_v2_1.ad_account_ids"},"widget_3":{"title":"Slack Channel","description":"Select a Slack Channel or Conversation","position":3,"input":"slack_select_conversation_id_1.conversation_id"}},"variables":{},"config":{"capture_inputs_enabled":false,"caching_enabled":false},"tags":[]}
How To
After creating the automation, make a few selections and then hit “Run Automation”. The check will happen by default every hour.
Per default, all active ads in an account will be checked. If you want to be more specific in the campaign, ad set, or ad selection you can add filters to the automation following this Builder tutorial.
Appstore links and internal links within Facebook or Instagram will be ignored.
Step 1
Select an Ad Account
Step 2
Select a Slack Channel, in which you would like to receive the notifications
Step 3
Define how often you want the automation to run
In order to check whether the URLs are healthy, we make a server-side request to each. Note that if your website uses Cloudflare, we may report URLs as unhealthy despite being accessible in your browser. Reach out to your CSM or contact us at support@kitchn.io if that is the case for you.
Did this answer your question?
😞
😐
🤩
Last updated on June 28, 2023